import java.util.Scanner;

/**
 * Created by forcht on 2018/4/26.
 */
public class Main {
    public static void main(String[] args) {
        Scanner scanner=new Scanner(System.in);
        while (scanner.hasNextInt()){
            int n=scanner.nextInt();
            int sum=0;
            for(int i=2;i<n;i++){
                sum+=addSum(n,i);
            }
            int r=f(sum,n-2);
            System.out.println(sum/r+"/"+(n-2)/r);
        }
    }
    static int f(int n,int m){
        int r;
        if(n<m){
            r=m;
            m=n;
            n=r;
        }
        while (n%m>0){
            r=n%m;
            n=m;
            m=r;
        }
        return m;
    }
    static int addSum(int m,int r){
        int sum=0;
        while (m>0){
            sum+=m%r;
            m/=r;
        }
        return sum;
    }
}
